#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>
#include <string.h>

//#include <stdio.h>

void print(char arr[], int sz)
{
    int i = 0;
    for (i = sz - 1; i >= 0; i--)
    {
        printf("%c", arr[i]);
    }
}
int main() {
    char i = 0;
    int j = 0;
    char arr[10000];
    while (scanf("%c", &i) != EOF)
    {
        arr[j] = i;
        j++;
    }
    arr[j + 1] = '\0';
    int count = strlen(arr);
    //int count = sizeof(arr)/sizeof(arr[0]);
    print(arr, count);
    return 0;
}